package com.workcell.workdata.xthings.dto;

import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;
import java.io.Serializable;
import java.util.List;

/**
 * @Author guoyu
 * @Date 2023/03/02 17:59
 * @Description
 */
public interface XthingsTvVo {

	@Data
	class UserPickRentVo implements Serializable {

		@NotEmpty(message = "设备Id不能为空")
		@ApiModelProperty(value="设备Id不能为空")
		private String deviceId;

		@NotEmpty(message = "设备编号不能为空")
		@ApiModelProperty(value="设备编号,这里用的是短链码")
		private String deviceNo;

		@NotNull(message = "用户不能为空")
		@ApiModelProperty(value="用户不能为空")
		private Long userId;

		@NotNull(message = "租户ID不能为空")
		@ApiModelProperty(value="租户ID不能为空")
		private Long rentId;

		@NotEmpty(message = "租户名称不能为空")
		@ApiModelProperty(value="租户名称不能为空")
		private String rentName;
	}

	@Data
	class SmartOSBoardVo implements Serializable {
		@ApiModelProperty(value="看板id")
		private Long id;

		@ApiModelProperty(value="看板名称")
		private String name;

		@ApiModelProperty(value="看板地址")
		private List<String> url;

		@ApiModelProperty(value="租户id")
		private Long rentId;

	}

	@Data
	class BoardVo implements Serializable {
		@NotEmpty(message = "设备编号不能为空")
		@ApiModelProperty(value="设备编号,这里用的是短链码")
		private String deviceNo;

		@ApiModelProperty(value="自定义看板配置")
		private List<Config> configs;

		@ApiModelProperty(value="TV跳转的地址集合")
		private List<BoardDetail> urlList;

		@ApiModelProperty(value="TV轮播周期min")
		private Integer playbackCycle;

		@ApiModelProperty(value="组装的jsonUrlList")
		private String jsonUrlList;

	}

	@Data
	class Config implements Serializable {
		@ApiModelProperty(value="高")
		private String dataHeight;

		@ApiModelProperty(value="宽")
		private String dataWidth;

		@ApiModelProperty(value="x")
		private String dataX;

		@ApiModelProperty(value="y")
		private String dataY;

		@ApiModelProperty(value="地址")
		private String src;

		@ApiModelProperty(value="名称")
		private String title;
	}

	@Data
	class BoardDetail implements Serializable {
		@ApiModelProperty(value="id")
		private Long id;

		@ApiModelProperty(value="TV跳转的地址")
		private String url;

		@ApiModelProperty(value="看板名称")
		private String title;

		@ApiModelProperty(value="当前播放看板:true 是;false 不是")
		private Boolean playing = false;
	}
}
